home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 5 / Apprentice-Release5.iso / Source Code / C++ / Applications / PICSee Dust 1.01 / Quaternary Source / QDUtils.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-11-07  |  1.1 KB  |  27 lines  |  [TEXT/CWIE]

  1. #ifndef _QDUTILS_H_
  2. #define _QDUTILS_H_
  3.  
  4. #ifndef __QDOFFSCREEN__
  5.     #include <QDOffscreen.h>
  6. #endif
  7.  
  8. inline BitMap* GetGWorldBits(GWorldPtr theGWorld)    { return((BitMap*)*GetGWorldPixMap(theGWorld)); }
  9. inline BitMap* GetWindowBits(WindowPtr theWindow)    { return(&theWindow->portBits); }
  10. inline BitMap* GetGrafBits(GrafPtr thePort)            { return(&thePort->portBits); }
  11.  
  12. void CopyBitsToWindow(GWorldPtr sourceGWorld, WindowPtr destWindow,
  13.     Rect *sourceR, Rect *destR, RgnHandle theClip = nil);
  14. void CopyBitsToGWorld(GWorldPtr sourceGWorld, GWorldPtr destGWorld,
  15.     Rect *sourceR, Rect *destR, RgnHandle theClip = nil);
  16.  
  17. void CenterRect(Rect *innerRect, Rect *outerRect);
  18. void MoveRectTo(Rect *theRect, short h, short v);
  19. void FlushRectTopLeft(Rect *theRect);
  20. void MoveRgnToRect(Rect *theRect, RgnHandle theRgn);
  21. void MoveRgnTo(short hLoc, short vLoc, RgnHandle theRgn);
  22.  
  23. void CenterText(Str255 theText, Rect *destRect, Boolean horizCenter, Boolean vertCenter);
  24.  
  25. void SetMonitorDepth(GDHandle monitor, short depth, Boolean color);
  26. Boolean HasMonitorDepth(GDHandle monitor, short depth, Boolean color);
  27. #endif    // _QDUTILS_H_